﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="CommunityFieldOfActivitiesEdit.ascx.cs"
    Inherits="Micronet.OpenWeb.OpenWeb.Admin.Views.Shared.OpenCommunity.CommunityFieldOfActivitiesEdit" %>
<style type="text/css">
    .style4
    {
        height: 36px;
    }
</style>
<owc:OwDetailsView ID="CommunityFieldOfActivitiesDv" runat="server" EnableModelValidation="True"
    OwNotificationID="" AutoGenerateRows="False" DataSourceID="CommunityFieldOfActivitiesOds" DataKeyNames="CommunityFieldOfActivityID">
    <Fields>
        <asp:TemplateField>
            <InsertItemTemplate>
                <fieldset>
                    <legend>
                        <owc:OwR runat="server" OwText="<%$ OwR:GeneralInfo %>" />
                    </legend>
                    <div>
                        <owac:OwDetailCommonGroup ID="OwDetailCommonGroup" runat="server" OwCategoryVisible="false"
                            OwAuthorVisible="false" OwSourceVisible="false" OwWardLocalityVisible="false"
                            OwBindLanguageValue='<%#Bind("LanguageCode")%>' />
                    </div>
                </fieldset>
                <fieldset>
                    <legend>
                        <owc:OwR runat="server" OwText="<%$ OwR:InfoLabel %>" />
                    </legend>
                    <table width="100%">
                        <tr>
                            <td>
                                <owc:OwR runat="server" OwText="<%$ OwR:CommunityFieldOfActivities %>" />
                            </td>
                            <td>
                                <owc:OwObjectDataSource ID="CommunityFieldOfActivitiesParentOds" runat="server" DataObjectTypeName="Micronet.OpenWeb.Entity.OwCommunityFieldOfActivitiesEntity"
                                    DeleteMethod="OwDelete" InsertMethod="OwInsert" OldValuesParameterFormatString="original_{0}"
                                    SelectMethod="OwGetByDynamic" TypeName="Micronet.OpenWeb.Com.BLL.OwCommunityFieldOfActivitiesBLL"
                                    UpdateMethod="OwUpdate">
                                    <SelectParameters>
                                        <asp:Parameter Name="parentID" Type="Int64" />
                                        <asp:Parameter Name="code" Type="String" />
                                        <asp:Parameter Name="isHomeDisplay" Type="Boolean" />
                                        <asp:Parameter Name="isHot" Type="Boolean" />
                                        <asp:Parameter Name="enableBegin" Type="DateTime" />
                                        <asp:Parameter Name="enableEnd" Type="DateTime" />
                                        <asp:Parameter Name="homeDisplayBegin" Type="DateTime" />
                                        <asp:Parameter Name="homeDisplayEnd" Type="DateTime" />
                                        <asp:Parameter Name="hotDisplayBegin" Type="DateTime" />
                                        <asp:Parameter Name="hotDisplayEnd" Type="DateTime" />
                                        <asp:Parameter Name="isApproved" Type="Boolean" />
                                        <asp:Parameter DefaultValue="false" Name="isDeleted" Type="Boolean" />
                                        <asp:Parameter DbType="Guid" Name="creatingUser" />
                                        <asp:Parameter DbType="Guid" Name="editingUser" />
                                        <asp:Parameter DbType="Guid" Name="deletingUser" />
                                        <asp:Parameter Name="languageCode" Type="String" />
                                        <asp:Parameter Name="isEnabled" Type="Boolean" />
                                        <asp:Parameter Name="sortClause" Type="String" />
                                        <asp:Parameter Name="sortDirection" Type="String" />
                                        <asp:Parameter Name="startRowIndex" Type="Int32" />
                                        <asp:Parameter Name="maximumRows" Type="Int32" />
                                    </SelectParameters>
                                </owc:OwObjectDataSource>
                                <owc:OwComboBox ID="CommunityFieldOfActivitiesParentCbb" runat="server" DataSourceID="CommunityFieldOfActivitiesParentOds"
                                    SkinID="OwComboBox" DataTextField="Name" DataValueField="CommunityFieldOfActivityID" SelectedValue='<%# Bind("ParentID") %>'>
                                </owc:OwComboBox>
                            </td>
                        </tr>
                        <tr>
                            <td class="leftcolumn">
                                <owc:OwR runat="server" OwText="<%$ OwR:Code %>" />
                            </td>
                            <td>
                                <owc:OwTextBox SkinID="OwTextBox" ID="CodeTxt" runat="server" Text='<%# Bind("Code") %>' />
                                <asp:RequiredFieldValidator Text="*" ID="RequiredFieldValidator1" runat="server"
                                    ErrorMessage=" <%$ OwR: CodeNotEmpty %>" ControlToValidate="CodeTxt"></asp:RequiredFieldValidator>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR runat="server" OwText="Name" />
                            </td>
                            <td>
                                <owc:OwTextBox ID="NameTxt" runat="server" Text='<%# Bind("Name") %>' SkinID="OwTextBox" />
                                <asp:RequiredFieldValidator Text="*" ID="RequiredFieldValidator2" runat="server"
                                    ErrorMessage=" <%$ OwR: NameNotEmpty %>" ControlToValidate="NameTxt" />
                            </td>
                            <tr>
                                <td>
                                    <owc:OwR OwText="SortOrder" runat="server"></owc:OwR>
                                </td>
                                <td>
                                    <owc:OwTextBox SkinID="owTextBox" ID="txtSortOrder" runat="server" Width="100px"
                                        Text='<%# Bind("SortOrder") %>' EmptyMessage="<%$ OwR: EnterSortOrder %>">
                                    </owc:OwTextBox>
                                      <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" Text="*"
    ErrorMessage="<%$ OwR:SortOrderIsNumber %>" ControlToValidate="txtSortOrder" 
    ValidationExpression="[0-9]*"></asp:RegularExpressionValidator>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                </td>
                                <td>
                                    <table style="padding: 20px 0;">
                                        <tr>
                                            <td style="padding-right: 20px;">
                                                <owc:OwCheckBox runat="server" ID="IsEnabledCbb" Text="<%$ OwR:IsEnabled %>" Checked='<%# Bind("IsEnabled") %>' />
                                            </td>
                                            <td style="padding-right: 20px;">
                                                <owc:OwCheckBox runat="server" ID="IsApprovedCbb" Text="<%$ OwR:IsApproved %>" Checked='<%# Bind("IsApproved") %>' />
                                            </td>
                                            <td style="padding-right: 20px;">
                                                <owc:OwCheckBox runat="server" ID="IsHomeDisplayCbb" Text="<%$ OwR:IsHomeDisplay %>"
                                                    Checked='<%# Bind("IsHomeDisplay") %>' />
                                            </td>
                                            <td style="padding-right: 20px;">
                                                <owc:OwCheckBox runat="server" ID="IsDeletedCbb" Text="<%$ OwR:IsDeleted %>" Checked='<%# Bind("IsDeleted") %>' />
                                            </td>
                                            <td style="padding-right: 20px;">
                                                <owc:OwCheckBox runat="server" ID="IsHotCbb" Text="<%$ OwR:IsHot %>" Checked='<%# Bind("IsHot") %>' />
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                </td>
                                <td>
                                    <table width="660px">
                                        <tr>
                                            <td class="style4">
                                             <owc:OwR  OwText="EnableBegin" runat="server" />    
                                            </td>
                                            <td class="style4">
                                                <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                                    ID="dtEnableBegin" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("EnableBegin") %>'
                                                    MaxDate="12/31/9999 23:59:59" MinDate="" OwDefaultValue='<%$ Ow: DateTime.Now %>'
                                                    OwUsedForEdit="False">
                                                    <TimeView CellSpacing="-1">
                                                    </TimeView>
                                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                                    <Calendar UseRowHeadersAsSelectors="False" UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                                    </Calendar>
                                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                                </owc:OwDateTimePicker>
                                            </td>
                                            <td class="style4">
                                                 <owc:OwR  OwText="EnableEnd" runat="server" />    
                                            </td>
                                            <td class="style4">
                                                <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                                    ID="dtEnableEnd" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("EnableEnd") %>'
                                                    MaxDate="12/31/9999 23:59:59" MinDate="" OwDefaultValue='<%$ Ow:OwPC.PCEx.DateTimeMax2 %>'
                                                    OwUsedForEdit="False">
                                                    <TimeView CellSpacing="-1">
                                                    </TimeView>
                                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                                    <Calendar ClientEvents-OnDateSelected="showNotification" UseRowHeadersAsSelectors="False"
                                                        UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                                    </Calendar>
                                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                                </owc:OwDateTimePicker>
                                                <asp:CompareValidator ID="CompareValidator1" runat="server" ControlToCompare="dtEnableBegin"
                                                    Display="Dynamic" ControlToValidate="dtEnableEnd" ErrorMessage="<%$ OwR:EnableEndGreaterThanEnableBegin %>"
                                                    Operator="GreaterThan" ValidationGroup="VDGroup"></asp:CompareValidator>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td class="style4">
                                              <owc:OwR  OwText="HomeDisplayBegin" runat="server" />       
                                            </td>
                                            <td class="style4">
                                                <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                                    Display="Dynamic" ID="dtIsHomeDisplayBegin" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("HomeDisplayBegin") %>'
                                                    MaxDate="12/31/9999 23:59:59" MinDate="" OwDefaultValue='<%$ Ow: DateTime.Now %>'
                                                    OwUsedForEdit="False">
                                                    <TimeView CellSpacing="-1">
                                                    </TimeView>
                                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                                    <Calendar ClientEvents-OnDateSelected="showNotification" UseRowHeadersAsSelectors="False"
                                                        UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                                    </Calendar>
                                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                                </owc:OwDateTimePicker>
                                                <asp:CompareValidator ID="CompareValidator3" runat="server" ControlToCompare="dtEnableBegin"
                                                    Display="Dynamic" ControlToValidate="dtIsHomeDisplayBegin" ErrorMessage="<%$ OwR:HomeDisplayBeginGreaterThanEqualEnableBegin %>"
                                                    ValidationGroup="VDGroup" Operator="GreaterThanEqual"></asp:CompareValidator>
                                            </td>
                                            <td class="style4">
                                          <owc:OwR  OwText="HomeDisplayEnd" runat="server" />           
                                            </td>
                                            <td class="style4">
                                                <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                                    ID="dtIsHomeDisplayEnd" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("HomeDisplayEnd") %>'
                                                    MaxDate="12/31/9999 23:59:59" MinDate="" OwDefaultValue='<%$ Ow:OwPC.PCEx.DateTimeMax2 %>'
                                                    OwUsedForEdit="False">
                                                    <ClientEvents OnDateSelected="showNotification"></ClientEvents>
                                                    <TimeView CellSpacing="-1">
                                                    </TimeView>
                                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                                    <Calendar UseRowHeadersAsSelectors="False" UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                                    </Calendar>
                                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                                </owc:OwDateTimePicker>
                                                <asp:CompareValidator ID="CompareValidator2" runat="server" ControlToCompare="dtEnableEnd"
                                                    Display="Dynamic" ControlToValidate="dtIsHomeDisplayEnd" ErrorMessage="<%$ OwR:HomeDisplayEndLessThanEqualEnableEnd %>"
                                                    Operator="LessThanEqual" ValidationGroup="VDGroup"></asp:CompareValidator>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td class="style4">
                                            <owc:OwR OwText="HotDisplayBegin" runat="server" />         
                                            </td>
                                            <td class="style4">
                                                <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                                    ID="dtIsHotBegin" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("HotDisplayBegin") %>'
                                                    MaxDate="12/31/9999 23:59:59" MinDate="" OwDefaultValue='<%$ Ow: DateTime.Now %>'
                                                    OwUsedForEdit="False">
                                                    <TimeView CellSpacing="-1">
                                                    </TimeView>
                                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                                    <Calendar UseRowHeadersAsSelectors="False" UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                                    </Calendar>
                                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                                </owc:OwDateTimePicker>
                                                <asp:CompareValidator ID="CompareValidator4" runat="server" ControlToCompare="dtEnableBegin"
                                                    Display="Dynamic" ControlToValidate="dtIsHotBegin" ErrorMessage="<%$ OwR:HotBeginGreaterThanEqualEnableBegin %>"
                                                    Operator="GreaterThanEqual" ValidationGroup="VDGroup"></asp:CompareValidator>
                                            </td>
                                            <td class="style4">
                                           <owc:OwR  OwText="HotDisplayEnd" runat="server" />          
                                            </td>
                                            <td class="style4">
                                                <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                                    ID="dtIsHotEnd" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("HotDisplayEnd") %>'
                                                    MaxDate="12/31/9999 23:59:59" OwDefaultValue='<%$ Ow:OwPC.PCEx.DateTimeMax2 %>'
                                                    OwUsedForEdit="False">
                                                    <TimeView CellSpacing="-1">
                                                    </TimeView>
                                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                                    <Calendar UseRowHeadersAsSelectors="False" UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                                    </Calendar>
                                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                                </owc:OwDateTimePicker>
                                                <asp:CompareValidator ID="CompareValidator5" runat="server" ControlToCompare="dtEnableEnd"
                                                    Display="Dynamic" ControlToValidate="dtIsHotEnd" ErrorMessage="<%$ OwR:HotEndLessThanEqualEnableEnd %>"
                                                    Operator="LessThanEqual" ValidationGroup="VDGroup"></asp:CompareValidator>
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR ID="ThumbImageOwR" runat="server" OwText="ThumbImage"></owc:OwR>
                            </td>
                            <td>
                                <owc:OwEditor ID="ThumbEditor" runat="server" OwStoragePlace="Common" Style="position: relative;"
                                    OwBindValue='<%# Bind("ThumbImage") %>' OwEditorType="OnlyInsertImage">
                                </owc:OwEditor>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR ID="ContentLabel" runat="server" OwText="ContentLabel" OwSuffix=":"></owc:OwR>
                            </td>
                            <td>
                                <owc:OwEditor ID="Detailtxt" runat="server" OwStoragePlace="Common" Content='<%# Bind("Description") %>'>
                                </owc:OwEditor>
                                <asp:RequiredFieldValidator Text="*" ID="RequiredFieldValidator3" runat="server"
                                    ControlToValidate="Detailtxt" ErrorMessage=" <%$ OwR: DetailNotEmpty %>"></asp:RequiredFieldValidator>
                            </td>
                        </tr>
                    </table>
                </fieldset>
              <fieldset>
                    <legend><span class="titleLegen">
                        <owc:OwR ID="OwR1" runat="server" OwText="ExtInfo" />
                    </span></legend>
                    <div>
                        <table width="100%">
                            <tr>
                                <td class="leftcolumn">
                                    <owc:OwR ID="CreatingUser" runat="server" OwText="CreatingUser" OwSuffix=":"></owc:OwR>
                                </td>
                                <td colspan="2">
                                     <owc:OwTextBox SkinID="OwTextBox" ID="CreatingUserTxt" runat="server" Enabled="False"
                                        Width="200px" OwUsedForEdit="False" Text='<%# Membership.GetUser()!=null? Membership.GetUser().UserName:"not loggedin!" %>'>
                                    </owc:OwTextBox>
                                    <owc:OwTextBox SkinID="OwTextBox" OwDefaultValue='<%# Membership.GetUser()!=null? Membership.GetUser().ProviderUserKey:null %>'
                                        ID="CreatingUserTxtBind" Visible="false" runat="server" Text='<%# Bind("CreatingUser")%>' />
                                </td>
                                <td>
                                    <asp:Localize ID="Localize6" runat="server" Text="<%$ OwR:CreatedDate %>"></asp:Localize>
                                    &nbsp;:
                                </td>
                                <td colspan="2">
                                   <owc:OwTextBox SkinID="OwTextBox" ID="DateTimeCreatedTxt" runat="server" Enabled="false"
                                        OwDefaultValue="<%$ Ow: DateTime.Now %>" OwUsedForEdit="false" Text='<%# Bind("DateTimeCreated") %>'>
                                    </owc:OwTextBox>
                                </td>
                            </tr>
                            <tr>
                                <td class="leftcolumn">
                                    <asp:Localize ID="Localize12" Text="<%$ OwR:LastEditingUser %>" runat="server"></asp:Localize>
                                    :
                                </td>
                                <td colspan="2">
                                    <owc:OwTextBox SkinID="owTextBox" ID="txtlastEditingUser" runat="server" Enabled="False"
                                        Width="200px" OwUsedForEdit="False" Text='<%#Eval("EditingUser")!=null? (Membership.GetUser(Eval("EditingUser"))!=null?Membership.GetUser(Eval("EditingUser")).UserName:"n/a"):"n/a"   %>'>
                                    </owc:OwTextBox>
                                    <owc:OwTextBox SkinID="owTextBox" OwDefaultValue='<%# Eval("EditingUser")!=null? (Membership.GetUser(Eval("EditingUser"))!=null?Membership.GetUser(Eval("EditingUser")).ProviderUserKey:""):""    %>'
                                        ID="EditingUserLabel" Visible="false" runat="server" Text='<%# Bind("EditingUser") %>' />
                                </td>
                                <td>
                                    <asp:Localize ID="Localize14" runat="server" Text="<%$ OwR:LastEditedDate %>"></asp:Localize>
                                    :
                                </td>
                                <td colspan="2">
                                    <owc:OwTextBox SkinID="owTextBox" ID="txtlastEditedDate" runat="server" Enabled="False"
                                        Width="200px" OwDefaultValue='<%$ Ow: DateTime.Now %>' OwUsedForEdit="False"
                                        Text='<%# Bind("DateTimeEdited") %>'>
                                    </owc:OwTextBox>
                                </td>
                            </tr>
                            <tr>
                                <td class="leftcolumn">
                                    <asp:Localize ID="Localize16" Text="<%$ OwR:DeletingUser %>" runat="server"></asp:Localize>
                                    :
                                </td>
                                <td colspan="2">
                                    <owc:OwTextBox SkinID="owTextBox" ID="txtdeletingUser" runat="server" Enabled="False"
                                        Width="200px" OwDefaultValue="" OwUsedForEdit="False" Text='<%# Bind("DeletingUser") %>'>
                                    </owc:OwTextBox>
                                </td>
                                <td>
                                    <asp:Localize ID="Localize17" runat="server" Text="<%$ OwR:DeletedDate %>"></asp:Localize>
                                    :
                                </td>
                                <td colspan="2">
                                    <owc:OwTextBox SkinID="owTextBox" ID="txtdeletedDate" runat="server" Enabled="False"
                                        Width="200px" OwDefaultValue="" OwUsedForEdit="False" Text='<%# Bind("DateTimeDeleted") %>'>
                                    </owc:OwTextBox>
                                </td>
                            </tr>
                        </table>
                    </div>
                </fieldset>
                <br />
                <br />
                <br />
            </InsertItemTemplate> 
            <EditItemTemplate>
                <fieldset>
                    <legend>
                        <owc:OwR runat="server" OwText="<%$ OwR:GeneralInfo %>" />
                    </legend>
                    <div>
                        <owac:OwDetailCommonGroup ID="OwDetailCommonGroup" runat="server" OwCategoryVisible="false"
                            OwAuthorVisible="false" OwSourceVisible="false" OwWardLocalityVisible="false"
                            OwBindLanguageValue='<%#Bind("LanguageCode")%>' />
                    </div>
                </fieldset>
                <fieldset>
                    <legend>
                        <owc:OwR runat="server" OwText="<%$ OwR:InfoLabel %>" />
                    </legend>
                    <table width="100%">
                        <tr>
                            <td>
                                <owc:OwR runat="server" OwText="<%$ OwR:CommunityFieldOfActivities %>" />
                            </td>
                            <td>
                                <owc:OwObjectDataSource ID="CommunityFieldOfActivitiesParentOds" runat="server" DataObjectTypeName="Micronet.OpenWeb.Entity.OwCommunityFieldOfActivitiesEntity"
                                    DeleteMethod="OwDelete" InsertMethod="OwInsert" OldValuesParameterFormatString="original_{0}"
                                    SelectMethod="OwGetByDynamic" TypeName="Micronet.OpenWeb.Com.BLL.OwCommunityFieldOfActivitiesBLL"
                                    UpdateMethod="OwUpdate">
                                    <SelectParameters>
                                        <asp:Parameter Name="parentID" Type="Int64" />
                                        <asp:Parameter Name="code" Type="String" />
                                        <asp:Parameter Name="isHomeDisplay" Type="Boolean" />
                                        <asp:Parameter Name="isHot" Type="Boolean" />
                                        <asp:Parameter Name="enableBegin" Type="DateTime" />
                                        <asp:Parameter Name="enableEnd" Type="DateTime" />
                                        <asp:Parameter Name="homeDisplayBegin" Type="DateTime" />
                                        <asp:Parameter Name="homeDisplayEnd" Type="DateTime" />
                                        <asp:Parameter Name="hotDisplayBegin" Type="DateTime" />
                                        <asp:Parameter Name="hotDisplayEnd" Type="DateTime" />
                                        <asp:Parameter Name="isApproved" Type="Boolean" />
                                        <asp:Parameter DefaultValue="false" Name="isDeleted" Type="Boolean" />
                                        <asp:Parameter DbType="Guid" Name="creatingUser" />
                                        <asp:Parameter DbType="Guid" Name="editingUser" />
                                        <asp:Parameter DbType="Guid" Name="deletingUser" />
                                        <asp:Parameter Name="languageCode" Type="String" />
                                        <asp:Parameter Name="isEnabled" Type="Boolean" />
                                        <asp:Parameter Name="sortClause" Type="String" />
                                        <asp:Parameter Name="sortDirection" Type="String" />
                                        <asp:Parameter Name="startRowIndex" Type="Int32" />
                                        <asp:Parameter Name="maximumRows" Type="Int32" />
                                    </SelectParameters>
                                </owc:OwObjectDataSource>
                                <owc:OwComboBox ID="CommunityFieldOfActivitiesParentCbb" runat="server" DataSourceID="CommunityFieldOfActivitiesParentOds"
                                    SkinID="OwComboBox" DataTextField="Name" DataValueField="CommunityFieldOfActivityID" SelectedValue='<%# Bind("ParentID") %>'>
                                </owc:OwComboBox>
                            </td>
                        </tr>
                        <tr>
                            <td class="leftcolumn">
                                <owc:OwR runat="server" OwText="<%$ OwR:Code %>" />
                            </td>
                            <td>
                                <owc:OwTextBox SkinID="OwTextBox" ID="CodeTxt" runat="server" Text='<%# Bind("Code") %>' />
                                <asp:RequiredFieldValidator Text="*" ID="RequiredFieldValidator1" runat="server"
                                    ErrorMessage=" <%$ OwR: CodeNotEmpty %>" ControlToValidate="CodeTxt"></asp:RequiredFieldValidator>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR runat="server" OwText="Name" />
                            </td>
                            <td>
                                <owc:OwTextBox ID="NameTxt" runat="server" Text='<%# Bind("Name") %>' SkinID="OwTextBox" />
                                <asp:RequiredFieldValidator Text="*" ID="RequiredFieldValidator2" runat="server"
                                    ErrorMessage=" <%$ OwR: NameNotEmpty %>" ControlToValidate="NameTxt" />
                            </td>
                            <tr>
                                <td>
                                    <owc:OwR OwText="SortOrder" runat="server"></owc:OwR>
                                </td>
                                <td>
                                    <owc:OwTextBox SkinID="owTextBox" ID="txtSortOrder" runat="server" Width="100px"
                                        Text='<%# Bind("SortOrder") %>' EmptyMessage="<%$ OwR: EnterSortOrder %>">
                                    </owc:OwTextBox>
                                      <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" Text="*"
    ErrorMessage="<%$ OwR:SortOrderIsNumber %>" ControlToValidate="txtSortOrder" 
    ValidationExpression="[0-9]*"></asp:RegularExpressionValidator>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                </td>
                                <td>
                                    <table style="padding: 20px 0;">
                                        <tr>
                                            <td style="padding-right: 20px;">
                                                <owc:OwCheckBox runat="server" ID="IsEnabledCbb" Text="<%$ OwR:IsEnabled %>" Checked='<%# Bind("IsEnabled") %>' />
                                            </td>
                                            <td style="padding-right: 20px;">
                                                <owc:OwCheckBox runat="server" ID="IsApprovedCbb" Text="<%$ OwR:IsApproved %>" Checked='<%# Bind("IsApproved") %>' />
                                            </td>
                                            <td style="padding-right: 20px;">
                                                <owc:OwCheckBox runat="server" ID="IsHomeDisplayCbb" Text="<%$ OwR:IsHomeDisplay %>"
                                                    Checked='<%# Bind("IsHomeDisplay") %>' />
                                            </td>
                                            <td style="padding-right: 20px;">
                                                <owc:OwCheckBox runat="server" ID="IsDeletedCbb" Text="<%$ OwR:IsDeleted %>" Checked='<%# Bind("IsDeleted") %>' />
                                            </td>
                                            <td style="padding-right: 20px;">
                                                <owc:OwCheckBox runat="server" ID="IsHotCbb" Text="<%$ OwR:IsHot %>" Checked='<%# Bind("IsHot") %>' />
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                </td>
                                <td>
                                    <table width="660px">
                                        <tr>
                                            <td class="style4">
                                             <owc:OwR  OwText="EnableBegin" runat="server" />    
                                            </td>
                                            <td class="style4">
                                                <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                                    ID="dtEnableBegin" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("EnableBegin") %>'
                                                    MaxDate="12/31/9999 23:59:59" MinDate="" OwDefaultValue='<%$ Ow: DateTime.Now %>'
                                                    OwUsedForEdit="False">
                                                    <TimeView CellSpacing="-1">
                                                    </TimeView>
                                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                                    <Calendar UseRowHeadersAsSelectors="False" UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                                    </Calendar>
                                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                                </owc:OwDateTimePicker>
                                            </td>
                                            <td class="style4">
                                                 <owc:OwR  OwText="EnableEnd" runat="server" />    
                                            </td>
                                            <td class="style4">
                                                <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                                    ID="dtEnableEnd" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("EnableEnd") %>'
                                                    MaxDate="12/31/9999 23:59:59" MinDate="" OwDefaultValue='<%$ Ow:OwPC.PCEx.DateTimeMax2 %>'
                                                    OwUsedForEdit="False">
                                                    <TimeView CellSpacing="-1">
                                                    </TimeView>
                                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                                    <Calendar ClientEvents-OnDateSelected="showNotification" UseRowHeadersAsSelectors="False"
                                                        UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                                    </Calendar>
                                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                                </owc:OwDateTimePicker>
                                                <asp:CompareValidator ID="CompareValidator1" runat="server" ControlToCompare="dtEnableBegin"
                                                    Display="Dynamic" ControlToValidate="dtEnableEnd" ErrorMessage="<%$ OwR:EnableEndGreaterThanEnableBegin %>"
                                                    Operator="GreaterThan" ValidationGroup="VDGroup"></asp:CompareValidator>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td class="style4">
                                              <owc:OwR  OwText="HomeDisplayBegin" runat="server" />       
                                            </td>
                                            <td class="style4">
                                                <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                                    Display="Dynamic" ID="dtIsHomeDisplayBegin" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("HomeDisplayBegin") %>'
                                                    MaxDate="12/31/9999 23:59:59" MinDate="" OwDefaultValue='<%$ Ow: DateTime.Now %>'
                                                    OwUsedForEdit="False">
                                                    <TimeView CellSpacing="-1">
                                                    </TimeView>
                                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                                    <Calendar ClientEvents-OnDateSelected="showNotification" UseRowHeadersAsSelectors="False"
                                                        UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                                    </Calendar>
                                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                                </owc:OwDateTimePicker>
                                                <asp:CompareValidator ID="CompareValidator3" runat="server" ControlToCompare="dtEnableBegin"
                                                    Display="Dynamic" ControlToValidate="dtIsHomeDisplayBegin" ErrorMessage="<%$ OwR:HomeDisplayBeginGreaterThanEqualEnableBegin %>"
                                                    ValidationGroup="VDGroup" Operator="GreaterThanEqual"></asp:CompareValidator>
                                            </td>
                                            <td class="style4">
                                          <owc:OwR  OwText="HomeDisplayEnd" runat="server" />           
                                            </td>
                                            <td class="style4">
                                                <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                                    ID="dtIsHomeDisplayEnd" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("HomeDisplayEnd") %>'
                                                    MaxDate="12/31/9999 23:59:59" MinDate="" OwDefaultValue='<%$ Ow:OwPC.PCEx.DateTimeMax2 %>'
                                                    OwUsedForEdit="False">
                                                    <ClientEvents OnDateSelected="showNotification"></ClientEvents>
                                                    <TimeView CellSpacing="-1">
                                                    </TimeView>
                                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                                    <Calendar UseRowHeadersAsSelectors="False" UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                                    </Calendar>
                                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                                </owc:OwDateTimePicker>
                                                <asp:CompareValidator ID="CompareValidator2" runat="server" ControlToCompare="dtEnableEnd"
                                                    Display="Dynamic" ControlToValidate="dtIsHomeDisplayEnd" ErrorMessage="<%$ OwR:HomeDisplayEndLessThanEqualEnableEnd %>"
                                                    Operator="LessThanEqual" ValidationGroup="VDGroup"></asp:CompareValidator>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td class="style4">
                                            <owc:OwR OwText="HotDisplayBegin" runat="server" />         
                                            </td>
                                            <td class="style4">
                                                <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                                    ID="dtIsHotBegin" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("HotDisplayBegin") %>'
                                                    MaxDate="12/31/9999 23:59:59" MinDate="" OwDefaultValue='<%$ Ow: DateTime.Now %>'
                                                    OwUsedForEdit="False">
                                                    <TimeView CellSpacing="-1">
                                                    </TimeView>
                                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                                    <Calendar UseRowHeadersAsSelectors="False" UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                                    </Calendar>
                                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                                </owc:OwDateTimePicker>
                                                <asp:CompareValidator ID="CompareValidator4" runat="server" ControlToCompare="dtEnableBegin"
                                                    Display="Dynamic" ControlToValidate="dtIsHotBegin" ErrorMessage="<%$ OwR:HotBeginGreaterThanEqualEnableBegin %>"
                                                    Operator="GreaterThanEqual" ValidationGroup="VDGroup"></asp:CompareValidator>
                                            </td>
                                            <td class="style4">
                                           <owc:OwR  OwText="HotDisplayEnd" runat="server" />          
                                            </td>
                                            <td class="style4">
                                                <owc:OwDateTimePicker SkinID="owDateTimePickerDetailAdmin" ClientEvents-OnDateSelected="showNotification"
                                                    ID="dtIsHotEnd" runat="server" Culture="en-US" DbSelectedDate='<%# Bind("HotDisplayEnd") %>'
                                                    MaxDate="12/31/9999 23:59:59" OwDefaultValue='<%$ Ow:OwPC.PCEx.DateTimeMax2 %>'
                                                    OwUsedForEdit="False">
                                                    <TimeView CellSpacing="-1">
                                                    </TimeView>
                                                    <TimePopupButton ImageUrl="" HoverImageUrl=""></TimePopupButton>
                                                    <Calendar UseRowHeadersAsSelectors="False" UseColumnHeadersAsSelectors="False" ViewSelectorText="x">
                                                    </Calendar>
                                                    <DatePopupButton ImageUrl="" HoverImageUrl=""></DatePopupButton>
                                                </owc:OwDateTimePicker>
                                                <asp:CompareValidator ID="CompareValidator5" runat="server" ControlToCompare="dtEnableEnd"
                                                    Display="Dynamic" ControlToValidate="dtIsHotEnd" ErrorMessage="<%$ OwR:HotEndLessThanEqualEnableEnd %>"
                                                    Operator="LessThanEqual" ValidationGroup="VDGroup"></asp:CompareValidator>
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR ID="ThumbImageOwR" runat="server" OwText="ThumbImage"></owc:OwR>
                            </td>
                            <td>
                              <owc:OwEditor ID="ImagesEditor" runat="server" OwEditorType="OnlyInsertImage" OwBindValue='<%# Bind("ThumbImage") %>'
                                    SkinID="OwEditorInsertImageOnly" Width="400" Height="150" Content='<%# String.Format("<img src={0} />",Eval("ThumbImage")) %>' />
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <owc:OwR ID="ContentLabel" runat="server" OwText="ContentLabel" OwSuffix=":"></owc:OwR>
                            </td>
                            <td>
                                <owc:OwEditor ID="Detailtxt" runat="server" OwStoragePlace="Common" Content='<%# Bind("Description") %>'>
                                </owc:OwEditor>
                                <asp:RequiredFieldValidator Text="*" ID="RequiredFieldValidator3" runat="server"
                                    ControlToValidate="Detailtxt" ErrorMessage=" <%$ OwR: DetailNotEmpty %>"></asp:RequiredFieldValidator>
                            </td>
                        </tr>
                    </table>
                </fieldset>
               <fieldset>
                    <legend><span class="titleLegen">
                        <asp:Localize ID="Localize23" Text="<%$ OwR: ExtInfo %>" runat="server"></asp:Localize>
                    </span></legend>
                    <div>
                      <table width="100%">
                            <tr>
                                <td class="leftcolumn">
                                    <owc:OwR ID="CreatingUser" runat="server" OwText="CreatingUser" OwSuffix=":"></owc:OwR>
                                </td>
                                <td>
                                  <owc:OwTextBox SkinID="OwTextBox" ID="CreatingUserTxt" runat="server" Enabled="False"
                                        Width="200px" OwUsedForEdit="true" OwDefaultValue='<%# Eval("CreatingUser")!=null ? Membership.GetUser(Eval("CreatingUser")).UserName:"n/a" %>'
                                        Text='<%# Eval("CreatingUser")!=null ? Membership.GetUser(Eval("CreatingUser")).UserName:"n/a" %>'>
                                    </owc:OwTextBox>
                                    <owc:OwTextBox SkinID="OwTextBox" OwDefaultValue='<%# Eval("CreatingUser")%>' ID="CreatingUserTxtBind"
                                        Visible="false" runat="server" Text='<%# Bind("CreatingUser")%>' />
                                </td>
                                <td>
                                    <asp:Localize ID="Localize6" runat="server" Text="<%$ OwR:CreatedDate %>"></asp:Localize>
                                    &nbsp;:
                                </td>
                                <td>
                                    <owc:OwTextBox SkinID="owTextBox" ID="txtCreatedDate" runat="server" Enabled="False"
                                        Width="200px" OwDefaultValue='<%$ Ow: DateTime.Now %>' OwUsedForEdit="false" Text='<%# Bind("DateTimeCreated") %>'>
                                    </owc:OwTextBox>
                                </td>
                            </tr>
                            <tr>
                                <td class="leftcolumn">
                                    <asp:Localize ID="Localize12" Text="<%$ OwR:LastEditingUser %>" runat="server"></asp:Localize>
                                    :
                                </td>
                                <td>
                                     <owc:OwTextBox SkinID="OwTextBox" ID="EditingUserTxt" runat="server" Enabled="False"
                                        Width="200px" OwUsedForEdit="true" OwDefaultValue='<%# Membership.GetUser()!=null ? Membership.GetUser().UserName:"not loggedin!" %>'
                                        Text='<%# Membership.GetUser()!=null ? Membership.GetUser().UserName:"not loggedin!" %>'>
                                    </owc:OwTextBox>
                                    <owc:OwTextBox SkinID="OwTextBox" OwDefaultValue='<%# Membership.GetUser()!=null ? Membership.GetUser().ProviderUserKey:null %>'
                                        ID="EditingUserTxtBind" Visible="false" runat="server" Text='<%# Bind("EditingUser")%>' />
                                </td>
                                <td>
                                    <asp:Localize ID="Localize14" runat="server" Text="<%$ OwR:LastEditedDate %>"></asp:Localize>
                                    :
                                </td>
                                <td>
                                    <owc:OwTextBox SkinID="owTextBox" ID="txtlastEditedDate" runat="server" Enabled="False"
                                        Width="200px" OwDefaultValue='<%$ Ow: DateTime.Now %>' OwUsedForEdit="true"
                                        Text='<%# Bind("DateTimeEdited") %>'>
                                    </owc:OwTextBox>
                                </td>
                            </tr>
                            <tr>
                                <td class="leftcolumn">
                                    <asp:Localize ID="Localize16" Text="<%$ OwR:DeletingUser %>" runat="server"></asp:Localize>
                                    :
                                </td>
                                <td>
                                    <owc:OwTextBox SkinID="owTextBox" ID="txtdeletingUser" runat="server" Enabled="False"
                                        Width="200px" OwDefaultValue="" OwUsedForEdit="False" Text='<%# Bind("DeletingUser") %>'>
                                    </owc:OwTextBox>
                                </td>
                                <td>
                                    <asp:Localize ID="Localize17" runat="server" Text="<%$ OwR:DeletedDate %>"></asp:Localize>
                                    :
                                </td>
                                <td>
                                    <owc:OwTextBox SkinID="owTextBox" ID="txtdeletedDate" runat="server" Enabled="False"
                                        Width="200px" OwDefaultValue="" OwUsedForEdit="False" Text='<%# Bind("DateTimeDeleted") %>'>
                                    </owc:OwTextBox>
                                </td>
                            </tr>
                        </table>
                    </div>
                </fieldset>
                <br />
                <br />
                <br />
            </EditItemTemplate>
        </asp:TemplateField>
        <asp:TemplateField ShowHeader="False">
            <EditItemTemplate>
                <fieldset style="position: fixed; bottom: 0px; right: 0px; width: 100%">
                    <legend>
                        <asp:Label ID="Label4" runat="server" EnableViewState="false" Text="<%$ OwR: Action %>" /></legend>
                    </owc:OwButton>
                    <owc:OwButton ID="EditUpdateThenCloseButton" runat="server" CommandName="Update"
                        Text='<%$OwR:Update %>' OnClientClicking="showNotification">
                    </owc:OwButton>
                    &nbsp;
                    <owc:OwConfirmButton ID="EditDeleteButton" runat="server" CausesValidation="True"
                        CommandName="Delete" Text="<%$OwR:Delete %>" SkinID="OwConfirmButton">
                    </owc:OwConfirmButton>
                    &nbsp;<owc:OwButton ID="EditCancelButton" runat="server" CausesValidation="False"
                        CommandName="Cancel" Text="<%$OwR:Cancel %>">
                    </owc:OwButton>
                </fieldset>
            </EditItemTemplate>
            <InsertItemTemplate>
                <fieldset style="position: fixed; bottom: 0px; right: 0px; width: 100%">
                    <legend>
                        <asp:Label ID="Label42" runat="server" EnableViewState="false" Text="<%$ OwR: Action %>" /></legend>
                    <owc:OwButton ID="InsertInsertButton" runat="server" CommandName="Insert" Text="<%$OwR:Insert %>"
                        OnClientClicking="showNotification">
                    </owc:OwButton>
                    &nbsp;<owc:OwButton ID="InsertCancelButton" runat="server" CausesValidation="False"
                        CommandName="Cancel" Text="<%$OwR:Cancel %>">
                    </owc:OwButton>
                </fieldset>
            </InsertItemTemplate>
        </asp:TemplateField>
    </Fields>
</owc:OwDetailsView>
<owc:OwObjectDataSource ID="CommunityFieldOfActivitiesOds" runat="server" DataObjectTypeName="Micronet.OpenWeb.Entity.OwCommunityFieldOfActivitiesEntity"
    DeleteMethod="OwDelete" InsertMethod="OwInsert" OldValuesParameterFormatString="original_{0}"
    SelectMethod="OwGetEntity" TypeName="Micronet.OpenWeb.Com.BLL.OwCommunityFieldOfActivitiesBLL"
    UpdateMethod="OwUpdate">
    <SelectParameters>
        <asp:QueryStringParameter Name="communityFieldOfActivityID" QueryStringField="Id"
            Type="Int64" />
    </SelectParameters>
</owc:OwObjectDataSource>
